Efforts have been made to save energy by controlling the dimming level of luminaires in a room. When a lot of daylight or other external light enters the room there is usually no need for a full power of the luminaires. On the other hand, by putting out the luminaires still the illumination level often becomes too low. Different solutions of controlling the dimming level, i.e. light output level, of luminaires based on determinations of the illumination at a level where people are working have been proposed. A resent control method has been published in an article entitled “Daylight integrated illumination control of LED systems based on enhanced presence sensing”, by Ashish Pandharipande and David Caicedo, Energy and Buildings, No. 43 (2011), pp. 944-950. A number of luminaires and co-arranged light sensors are mounted at the ceiling, which is a first level. The luminaires are individually identified by coding of the light that they emit. Initially, the luminaires are turned on at a predetermined dimming level, and a commissioning is performed where the illumination is measured (i) at many positions in a workspace plane, i.e. where the people are supposed to work, which is a second level, and (ii) at the first level. On basis of the measurements a mapping table is calculated, where the illumination values at the second level are mapped to illumination values at the first level. During the following normal operation the illumination is repeatedly detected by means of the light sensors at the first level, and by means of the mapping table corresponding illumination values are determined for a number of positions at the second level. The illumination is divided into a daylight part, i.e. illumination caused by surrounding daylight, and a luminaire part, i.e. illumination caused by all the luminaires. Then an optimization is mathematically performed for all positions in common, and, finally, corresponding dimming levels of the luminaires are set. This is a nice method, which does not need any light sensors at the second level for the continuous operation, and which provides an optimized setting of a plurality of luminaires in common. However the prior art method is unnecessarily complex for many applications. Thus, a simpler method that can be used for one or more luminaires but still does not require level two measurements for the normal operation is desired.